<%@page import="cn.com.gzqd.model.Book"%>
<%@page import="cn.com.gzqd.serviceimpl.BookServiceImpl"%>
<%@page import="java.util.Iterator"%>
<%@page import="java.util.List"%>

<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>doDelete</title>
</head>
<%
	request.setCharacterEncoding("GBk");
%>
<body>
<%		BookServiceImpl psi=new BookServiceImpl();
		Book book=new Book();
		String xh=request.getParameter("xh");
		if(xh!=null){
			book.setId( Integer.parseInt(xh, 10));
		}
		try{
			if(psi.Delete(book)){
		
	%>
	<h3>信息删除成功！</h3>
	<jsp:forward page="PageServlet"></jsp:forward>
	<%
			}else{
	%>
	<h3>信息删除失败</h3>
	<%
		}
			}
			catch(Exception e){
				e.printStackTrace();
				}
			
	%>
</body>
</html>